package com.fz.us.oa.core.entity.com;


import com.fz.us.admin.company.entity.BaseFlowEntity;

import javax.persistence.*;

/**
 * Created by ZhuChunXiao on 2017/5/23.
 * 异动总汇
 */
@Entity
@Table(name="ec_allchange")
public class AllChange extends BaseFlowEntity {
    private static final long serialVersionUID = 4403342279957820750L;
    /**
     * 变动类型 1转正申请 2续约申请 3离职申请 4调动申请
     */
    private String type;
    /**
     * 人事信息表
     */
    private PersonnelInfo personnelInfo;
    /**
     * 续签申请
     */
    private Renewal renewal;
    /**
     * 调动申请
     */
    private Transfer transfer;
    /**
     * 离职申请
     */
    private Quit quit;
    /**
     * 转正申请
     */
    private Formal formal;
    /**
     * 是否归档 0流转中 1已归档
     */
    private String isFinished;

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    @ManyToOne(fetch = FetchType.LAZY)
    public PersonnelInfo getPersonnelInfo() {
        return personnelInfo;
    }

    public void setPersonnelInfo(PersonnelInfo personnelInfo) {
        this.personnelInfo = personnelInfo;
    }

    @OneToOne(fetch = FetchType.LAZY)
    public Renewal getRenewal() {
        return renewal;
    }

    public void setRenewal(Renewal renewal) {
        this.renewal = renewal;
    }


    @OneToOne(fetch = FetchType.LAZY)
    public Transfer getTransfer() {
        return transfer;
    }

    public void setTransfer(Transfer transfer) {
        this.transfer = transfer;
    }

    @OneToOne(fetch = FetchType.LAZY)
    public Quit getQuit() {
        return quit;
    }

    public void setQuit(Quit quit) {
        this.quit = quit;
    }

    @OneToOne(fetch = FetchType.LAZY)
    public Formal getFormal() {
        return formal;
    }

    public void setFormal(Formal formal) {
        this.formal = formal;
    }


    public String getIsFinished() {
        return isFinished;
    }

    public void setIsFinished(String isFinished) {
        this.isFinished = isFinished;
    }
}
